from django.contrib import admin
from profile.models import UserProfile, ProfileImage, Connection


# class ImageAdmin(admin.ModelAdmin):
    # list_display = ('name', 'admin_thumbnail_view',)

# class PlaceAdmin(admin.ModelAdmin):
    # exclude = ('modified_date', 'created_date')

# class DishAdmin(admin.ModelAdmin):
    # exclude = ('modified_date', 'created_date')

class ProfileImageInline(admin.TabularInline):
    model = ProfileImage

class FollowersInline(admin.TabularInline):
    model = Connection
    fk_name = 'leader'

class FollowingInline(admin.TabularInline):
    model = Connection
    fk_name = 'follower'

class UserProfileAdmin(admin.ModelAdmin):
    inlines = [
        ProfileImageInline,
        FollowersInline,
        FollowingInline,
    ]

admin.site.register(UserProfile, UserProfileAdmin)
# admin.site.register(ProfileImage)
# admin.site.register(Dish)
# admin.site.register(PlaceImage, ImageAdmin)
# admin.site.register(DishImage, ImageAdmin)
# admin.site.register(Review)

# admin.site.register(Tag)
# admin.site.register(Tag_Relation)